<mat-tab-group
  *ngIf="!isScoreImprovement; else scoreImprovement"
  animationDuration="0ms"
  [selectedIndex]="groupsService.activeTabIndex"
  (selectedTabChange)="activateTab($event)">
  <mat-tab
    label="{{ 'group.gridHeader.MEMBERS' | translate }}"
  >
    <app-members
      *ngIf="groupsService.activeTabIndex === 0"
      [source]="navSource"
      [members]="members"
      [kind]="kind"
      [resizableHeight]="resizableHeight">
    </app-members>
  </mat-tab>
  <mat-tab
    label="{{ 'group.script.TITLE' | translate }}"
    [labelClass]="(kind==='container' || kind==='node') && cfgType !== CFG_TYPE.FED ? '' : 'hide'"
  >
    <app-custom-check
      *ngIf="groupsService.activeTabIndex === 1 && ((kind==='container' || kind==='node') && cfgType !== CFG_TYPE.FED)"
      [source]="navSource"
      [groupName]="selectedGroupName"
      [resizableHeight]="resizableHeight">
    </app-custom-check>
  </mat-tab>
  <mat-tab
    label="{{ 'service.PROCESS_PROFILE' | translate }}"
    [labelClass]="kind==='container' || kind==='node' ? '' : 'hide'"
  >
    <app-process-profile-rules
      *ngIf="groupsService.activeTabIndex === 2 && (kind==='container' || kind==='node')"
      [source]="navSource"
      [groupName]="selectedGroupName"
      [resizableHeight]="resizableHeight"
      [cfgType]="cfgType"
    >
    </app-process-profile-rules>
  </mat-tab>
  <mat-tab
    label="{{ 'service.FILE_PROFILE' | translate }}"
    [labelClass]="kind==='container' ? '' : 'hide'"
  >
    <app-file-access-rules
      *ngIf="groupsService.activeTabIndex === 3 && kind==='container'"
      [source]="navSource"
      [groupName]="selectedGroupName"
      [resizableHeight]="resizableHeight"
      [cfgType]="cfgType"
    >
    </app-file-access-rules>
  </mat-tab>
  <mat-tab
    label="{{ 'service.POLICY_RULES' | translate }}"
  >
    <app-network-rules
      *ngIf="groupsService.activeTabIndex === 4"
      [source]="navSource"
      [groupName]="selectedGroupName"
      [resizableHeight]="resizableHeight">
    </app-network-rules>
  </mat-tab>
  <mat-tab
    label="{{ 'group.RESPONSE_RULES' | translate }}"
  >
    <app-response-rules
      *ngIf="groupsService.activeTabIndex === 5"
      [source]="navSource"
      [groupName]="selectedGroupName"
      [resizableHeight]="resizableHeight">
    </app-response-rules>
  </mat-tab>
  <mat-tab
    label="{{ 'group.dlp.TITLE' | translate }}"
    [labelClass]="kind==='container' && cfgType !== CFG_TYPE.FED ? '' : 'hide'"
  >
    <app-group-dlp
      *ngIf="groupsService.activeTabIndex === 6 && (kind==='container' && cfgType !== CFG_TYPE.FED)"
      [source]="navSource"
      [groupName]="selectedGroupName"
      [cfgType]="cfgType"
      [resizableHeight]="resizableHeight">
    </app-group-dlp>
  </mat-tab>
  <mat-tab
    label="{{ 'group.waf.TITLE' | translate }}"
    [labelClass]="kind==='container' && cfgType !== CFG_TYPE.FED ? '' : 'hide'"
  >
    <app-group-waf
      *ngIf="groupsService.activeTabIndex === 7 && (kind==='container' && cfgType !== CFG_TYPE.FED)"
      [source]="navSource"
      [cfgType]="cfgType"
      [groupName]="selectedGroupName"
      [resizableHeight]="resizableHeight">
    </app-group-waf>
  </mat-tab>
</mat-tab-group>
<ng-template #scoreImprovement>
  <mat-tab-group
    animationDuration="0ms"
    (selectedTabChange)="activateTab($event)">
    <mat-tab label="{{ 'service.PROCESS_PROFILE' | translate }}">
      <ng-template matTabContent>
        <app-process-profile-rules
          [source]="navSource"
          [groupName]="selectedGroupName"
          [resizableHeight]="resizableHeight"
          [isScoreImprovement]="isScoreImprovement"
          [cfgType]="cfgType"
        >
        </app-process-profile-rules>
      </ng-template>
    </mat-tab>
    <mat-tab
      label="{{ 'service.FILE_PROFILE' | translate }}"
      *ngIf="kind === 'container'">
      <ng-template matTabContent>
        <app-file-access-rules
          [source]="navSource"
          [groupName]="selectedGroupName"
          [resizableHeight]="resizableHeight"
          [isScoreImprovement]="isScoreImprovement"
          [cfgType]="cfgType"
        >
        </app-file-access-rules>
      </ng-template>
    </mat-tab>
    <mat-tab label="{{ 'service.POLICY_RULES' | translate }}">
      <ng-template matTabContent>
        <app-network-rules
          [source]="navSource"
          [groupName]="getServiceName(selectedGroupName)"
          [resizableHeight]="resizableHeight"
          [isScoreImprovement]="isScoreImprovement">
        </app-network-rules>
      </ng-template>
    </mat-tab>
  </mat-tab-group>
</ng-template>
